<?php

class Calcparams extends DirModel
{
	
	
public function getUpdateFields()
	{
		return array(
			'param_name',
			array(
				'name'=>'param_value',
				'editor'=>'memo',
				'cols'=>50,
				'rows'=>10,
			),
		);
	}

	/**
	 * @return string the associated database table name
	 */
	public function tableName()
	{
		return 'ut_calc_params';
	}

	/**
	 * @return array validation rules for model attributes.
	 */
	public function rules()
	{
		// NOTE: you should only define rules for those attributes that
		// will receive user inputs.
		return array(
			array('param_name,param_value', 'required'),
			//array('param_name,param_value', 'length', 'max'=>255),
		);
	}

	public function scopes()
	{
		return array(
			);
	}	
	
	
	/**
	 * @return array relational rules.
	 */
	public function relations()
	{
		// NOTE: you may need to adjust the relation name and the related
		// class name for the relations automatically generated below.
		return array(
		);
	}

	/**
	 * @return array customized attribute labels (name=>label)
	 */
	public function attributeLabels()
	{
		return array(
			'param_name' => 'Параметр',
			'param_value' => 'Значение',
		);
	}

}
